#!/bin/sh
[ $# -eq 0 ] && { echo "A parameter is expected. Usage: $0 destination-dir"; exit 1; }

cp .gitignore $1
cp .jscsrc $1
cp .eslintrc $1
cp .eslintignore $1

cp server.js $1
cp syncto.sh $1
cp webpack.config.js $1

mkdir $1/git-hooks 2> /dev/null
cp -r git-hooks/ $1/git-hooks

mkdir $1/assets 2> /dev/null
cp assets/do-not-remove.png $1/assets

mkdir $1/src 2> /dev/null
mkdir $1/src/external 2> /dev/null
cp -r src/external/ $1/src/external

mkdir $1/test 2> /dev/null
cp test/setup.js $1/test

git diff package.json $1/package.json
git diff index.html $1/index.html
git diff src/index.js $1/src/index.js
